// 右侧组件对应配置

//题目配置，通用
const topicOptions = {
  writerPlaceholderOptions: [
    { label: '默认', value: 0 },
    { label: '手动填写', value: 1 },
  ],
  widthOptions: [
    { label: '100', value: 100 },
    { label: '200', value: 200 },
    { label: '300', value: 300 },
    { label: '400', value: 400 },
    { label: '500', value: 500 },
    { label: '600（默认）', value: 600 },
  ],
  heightOptions: [
    { label: '40（默认）', value: 40 },
    { label: '80', value: 80 },
    { label: '120', value: 120 },
    { label: '160', value: 160 },
    { label: '200', value: 200 },
    { label: '240', value: 240 },
    { label: '280', value: 280 },
    { label: '320', value: 320 },
  ]
}
const designOptions = {
  writerPlaceholderOptions: [
    { label: '默认', value: 0 },
    { label: '手动填写', value: 1 },
  ],
  widthOptions: [
    { label: '100', value: 100 },
    { label: '200', value: 200 },
    { label: '300', value: 300 },
    { label: '400', value: 400 },
    { label: '500', value: 500 },
    { label: '600（默认）', value: 600 },
  ],
  heightOptions: [
    { label: '40（默认）', value: 40 },
    { label: '80', value: 80 },
    { label: '120', value: 120 },
    { label: '160', value: 160 },
    { label: '200', value: 200 },
    { label: '240', value: 240 },
    { label: '280', value: 280 },
    { label: '320', value: 320 },
  ],
  formatOptions: [
    { label: '不限制', value: 0 },
    { label: '数字', value: 1 },
    { label: '手机号码', value: 2 },
    { label: '身份证号', value: 3 },
    { label: '邮箱', value: 4 },
    { label: '汉字', value: 5 },
    { label: '英文', value: 6 },
  ],
  numFormatOptions: [
    { label: '不限制', value: 0 },
    { label: '限整数', value: 1 },
    { label: '允许小数', value: 2 }
  ],
  inputWordsNumFormatOptions: [
    { label: '不限制', value: 0 },
    { label: '不超过', value: 1 },
    { label: '固定为', value: 3 },
    { label: '介于', value: 4 }
  ],
  wordsNumFormatOptions: [
    { label: '不限制', value: 0 },
    { label: '不超过', value: 1 },
    { label: '不少于', value: 2 },
    { label: '固定为', value: 3 },
    { label: '介于', value: 4 }
  ],
  repeatedSubmitOptions: [
    { label: '不允许', value: 0 },
    { label: '允许', value: 1 },
  ],
  districtLevelOptions: [
    { label: '省', value: 1 },
    { label: '市', value: 2 },
    { label: '区', value: 3 },
  ]
}
//多选框配置
const checkboxOptions = {
  selectMaxOptions:[
    {label:'不限制',value:999},
    {label:'1个',value:1},
    {label:'2个',value:2},
    {label:'3个',value:3},
    {label:'5个',value:5}
  ],
  selectMinOptions:[
    {label:'不限制',value:0},
    {label:'1个',value:1},
    {label:'2个',value:2},
    {label:'3个',value:3},
    {label:'5个',value:5}
  ]
}
// 直接插入题目时使用的模板题目
const modelQuestion = {
  type: "input",
  label: "",
  compName: '单项填空', //组件名
  labelIndex: null, //索引
  labelPlaceholder: "请输入题目标题", //标题
  description: '', //描述
  descriptionFile: '', //描述（附件）
  descriptionPlaceholder: '请输入题目描述（选填）', //描述Placeholder
  writerPlaceholder: '', //填写者默认输入提示
  writerPlaceholderType: 0, //填写者输入提示类型
  require: true, //是否必填,
  format: 0, //格式
  numFormat: 0, //格式为数字时的限制
  wordsNumFormat: 0, //字数限制类型
  wordsNum: 38, //字数限制
  wordsNumRange: [5, 38], //字数限制（介于）
  repeatedSubmit: 0, //是否允许重复提交
  inputMaxWords: 38, //单项填空回答区最大字数限制
  width: 600, //宽度
  height: 40 , //高度
  formItemId: "", //前端生成的唯一id
  default: null,
}
const fileSecretKey = '&secret=786dAANTAwUDVAEGAF4BDghXAFAHWgFXUgQEB1JT'//附件密钥
export {  
  topicOptions, designOptions, checkboxOptions, modelQuestion, fileSecretKey
}
